package com.exchange.common.model.dto;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;

import cn.hutool.json.JSONUtil;


/**
 *- 说明： 订单实体类
 */
public class Order implements Serializable {

	private static final long serialVersionUID = 10000L;

	// @ApiModelProperty(name = "id" , value = "主键")
	private Long id;

	// @ApiModelProperty(name = "uid" , value = "用户ID")
	private Long uid;

	// @ApiModelProperty(name = "isBuy" , value = "是否是买单")
	private Boolean isBuy;

	// @ApiModelProperty(name = "isMarket" , value = "是市价交易")
	private Boolean isMarket;

//	@DecimalMin("0")
	// @ApiModelProperty(name = "number" , value = "交易数量")
	private BigDecimal number;

//	@DecimalMin("0")
	// @ApiModelProperty(name = "price" , value = "单价")
	private BigDecimal price;

//	@DecimalMin("0")
	// @ApiModelProperty(name = "totalPrice" , value = "总价")
	private BigDecimal totalPrice;
    
    // @ApiModelProperty(name = "dealWay" , value = "成交方式（taker市价，maker限价）")
	private String dealWay;
    
//	@DecimalMin("0")
	// @ApiModelProperty(name = "finishNumber" , value = "已完成数量")
	private BigDecimal finishNumber;

//	@DecimalMin("0")
	// @ApiModelProperty(name = "unFinishNumber" , value = "未完成数量")
	private BigDecimal unFinishNumber;

//	@DecimalMin("0")
	// @ApiModelProperty(name = "surplusFrozen" , value = "剩余冻结")
	private BigDecimal surplusFrozen;

	// @ApiModelProperty(name = "priority" , value = "优先级（越大越优先）")
	private Integer priority;

	// @ApiModelProperty(name = "state" , value =
	// -1支付失败, 0已支付,1部分成交,2全部成交,3已撤销,4撤销申请,5异常订单
	private Integer state;

	// @ApiModelProperty(name = "decimalNumber" , value = "数量的小数位数，其他以传入为准")
	private Integer decimalNumber;

	// @ApiModelProperty(name = "coinTeam" , value = "交易队")
	private String coinTeam;
	
	// @ApiModelProperty(name = "createTime" , value = "创建时间")
//	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	private Date createTime;

    // @ApiModelProperty(name = "alterTime" , value = "修改时间")
//    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	private Date alterTime;

	// @ApiModelProperty(name = "remark" , value = "备用字段JSON格式")
	private String remark;

	
	
	public Long getId() {
		return id;
	}



	public void setId(Long id) {
		this.id = id;
	}



	public Long getUid() {
		return uid;
	}



	public void setUid(Long uid) {
		this.uid = uid;
	}



	public Boolean getIsBuy() {
		return isBuy;
	}



	public void setIsBuy(Boolean isBuy) {
		this.isBuy = isBuy;
	}



	public Boolean getIsMarket() {
		return isMarket;
	}



	public void setIsMarket(Boolean isMarket) {
		this.isMarket = isMarket;
	}



	public BigDecimal getNumber() {
		return number;
	}



	public void setNumber(BigDecimal number) {
		this.number = number;
	}



	public BigDecimal getPrice() {
		return price;
	}



	public void setPrice(BigDecimal price) {
		this.price = price;
	}



	public BigDecimal getTotalPrice() {
		return totalPrice;
	}



	public void setTotalPrice(BigDecimal totalPrice) {
		this.totalPrice = totalPrice;
	}



	public String getDealWay() {
		return dealWay;
	}



	public void setDealWay(String dealWay) {
		this.dealWay = dealWay;
	}



	public BigDecimal getFinishNumber() {
		return finishNumber;
	}



	public void setFinishNumber(BigDecimal finishNumber) {
		this.finishNumber = finishNumber;
	}



	public BigDecimal getUnFinishNumber() {
		return unFinishNumber;
	}



	public void setUnFinishNumber(BigDecimal unFinishNumber) {
		this.unFinishNumber = unFinishNumber;
	}



	public BigDecimal getSurplusFrozen() {
		return surplusFrozen;
	}



	public void setSurplusFrozen(BigDecimal surplusFrozen) {
		this.surplusFrozen = surplusFrozen;
	}



	public Integer getPriority() {
		return priority;
	}



	public void setPriority(Integer priority) {
		this.priority = priority;
	}



	public Integer getState() {
		return state;
	}



	public void setState(Integer state) {
		this.state = state;
	}



	public Integer getDecimalNumber() {
		return decimalNumber;
	}



	public void setDecimalNumber(Integer decimalNumber) {
		this.decimalNumber = decimalNumber;
	}



	public String getCoinTeam() {
		return coinTeam;
	}



	public void setCoinTeam(String coinTeam) {
		this.coinTeam = coinTeam;
	}



	public Date getCreateTime() {
		return createTime;
	}



	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}



	public Date getAlterTime() {
		return alterTime;
	}



	public void setAlterTime(Date alterTime) {
		this.alterTime = alterTime;
	}



	public String getRemark() {
		return remark;
	}



	public void setRemark(String remark) {
		this.remark = remark;
	}



	public String toJsonString() {
		return JSONUtil.toJsonStr(this);
	}
}
